import { guideCenter } from "../guideCenter";
import { GuideCmd, GuideExeSequence, GuideWeakClickType, IGuideConfig, IGuideWeakArgs } from "../iGuide";

const guide_1 = <IGuideConfig>{
    id: 1,
    name: "点击按钮",
    isRunGuide: true,
    isLocalSave: false,
    exeSequence: GuideExeSequence.Queue,
    steps: [
        {
            desc: "点击按钮1",
            command: {
                cmd: GuideCmd.WeakGuide,
                args: <IGuideWeakArgs>{
                    locator: "UI/Btn1",
                    clickType: GuideWeakClickType.Node,
                    waitTime: 3
                }
            },
        },
        {
            desc: "点击按钮2",
            command: {
                cmd: GuideCmd.WeakGuide,
                args: <IGuideWeakArgs>{
                    locator: "UI/Btn2",
                    clickType: GuideWeakClickType.Global,
                    waitTime: 0
                }
            },
        },
    ],
    onComplete: () => {
        guideCenter.triggerGuide(2);
    }
}

guideCenter.registerGuide(guide_1);
